<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<%@ include file="../../../commons/taglibs.jsp"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
		<base href="<%=basePath%>">
		<title>列表</title>
		<meta http-equiv="pragma" content="no-cache">
		<meta http-equiv="cache-control" content="no-cache">
		<meta http-equiv="expires" content="0">
		<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
		<meta http-equiv="description" content="This is my page">
</head>
<body>

		<form id="queryForm" name="queryForm" method="post" 	>
			<div id="tab_bd1">
				<div class="title">
					<div class="left">
						查询筛选
					</div>
				</div>
				<div class="frame">
					<table width="100%" border="0" cellpadding="1" cellspacing="1" bordercolor="#CCCCCC" bgcolor="#CCCCCC" align="center">
						<tr>
							<td class="lbg" width="120">
								菜单名称：
							</td>
							<td>
								<input name="outMenu.name" id="name" type="text" size="30">
							</td>
						</tr>

						<tr>
							<td class="lbg" width="60" colspan="8">
								<a id="btn" href="javascript:queryUi()" class="easyui-linkbutton" data-options="iconCls:'icon-search'">查询</a>
								<a id="btn" href="javascript:rebackUi()" class="easyui-linkbutton" data-options="iconCls:'icon-reload'">返回</a>
							</td>
						</tr>
					</table>
				</div>
			</div>
		</form>

		<!-- 数据集合部分 -->	
	<table id="list_data" > </table>
		
	<script type="text/javascript">
	/**  页面加载自动加载datagrid数据 **/
	$(function(){
			$('#list_data').datagrid({  
		        title:'菜单列表',  
		        iconCls:'icon-edit',// 图标
		        width: 'auto',  
		        height:370,  
		        nowrap: false,  
		        striped: true,  
		        border: true,  
		        loadMsg:'数据加载中请稍后……',
		        collapsible:true,// 是否可折叠的
		        fit: false,// 自动大小
		        url:'<%=path %>/menu/list',  
		        remoteSort:false,   
		        singleSelect:false,// 是否单选
		        pagination:true,// 分页控件
		        pageSize: 10,// 每页显示的记录条数，默认为10
		        pageList: [10,20,50],// 可以设置每页记录条数的列表
		        rownumbers:true,// 行号
		        columns:[[
		                  {field:'name',title:'菜名',width:200,align:'center'},
		                  {field:'price',title:'单价',width:100,align:'center'},
		                  {field:'descption',title:'描述',width:350,align:'center'}
		                  ]],
		        frozenColumns:[[  
		            {field:'id',checkbox:true}  
		        ]],
		        toolbar: [{  
		            text: '添加',  
		            iconCls: 'icon-add',  
		            handler: function() {  
		             	addDialogTag("<%=path %>/jsp/OutMenu/form.jsp",'添加菜单','<%=path %>/menu/createOrUpdate','450','420');   
		            }  
		        }, '-', {  
		            text: '修改',  
		            iconCls: 'icon-edit',  
		            handler: function() {  
		        		beforeUpdateDialogTag('<%=path %>/menu/edit?id=','id','修改菜单','<%=path %>/menu/createOrUpdate','450','420');
		                
		            }  
		        }, '-',{  
		            text: '删除',  
		            iconCls: 'icon-remove',  
		            handler: function(){  
		                delAppInfo('<%=path %>/busInfo/delete?items=','id' );  
		            }  
		        }]
		    });  

			var p = $('#list_data').datagrid('getPager');  
		    $(p).pagination({  
		        pageSize: 10,//每页显示的记录条数，默认为10  
		        pageList: [10,20,50],//可以设置每页记录条数的列表  
		        beforePageText: '第',//页数文本框前显示的汉字  
		        afterPageText: '页     共{pages}页',  
		        displayMsg: '当前显示 {from} - {to} 条记录   共 {total}条记录'
		    }); 
	}); 	
</script>
</body>	
</html>
	
